package com.fitness.front.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.fitness.front.modal.coach.entity.CoachComment;
import com.fitness.front.modal.coach.param.CoachCommentQueryParams;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

public interface CoachCommentMapper extends BaseMapper<CoachComment> {

    @Select("select * from t_coach_comment c where c.coach_id = #{queryParams.coachId} order by create_time desc")
    Page<CoachComment> getCoachCommentPage(Page<CoachComment> page, @Param("queryParams") CoachCommentQueryParams queryParams);
}
